<template>
	<kb-layout title="出行人管理">
		
		<view class="u-padding-30">
			<view class="line-border u-margin-bottom-30"> </view>
			<addPeopleVue :isRefresh="isRefresh"></addPeopleVue>
		</view>
		
		
	</kb-layout>
</template>

<script setup>
	import { ref,watch } from "vue";
	import addPeopleVue from './component/add-people.vue';
	import {
		usePageStore
	} from "@/common/tools/store.js"
	
	
	const isRefresh = ref(null);
	
	const store = usePageStore();
	
	 watch(() => store.backRefresh, (n, o) => {	 
		//这里用pros.isRefresh监听 它从父组件传递进来。
		//父组件也可能有数据要更新。
		if (n == true) {	
			isRefresh.value = !isRefresh.value;
			 // fetchData();
			 store.setBackRefresh(false); //重置掉
		}
	 })
</script>

<style lang="scss" scoped>
	page{
		background-color: #fff;
	}
</style>